<template>
  <el-data-table
    :url="url"
    :columns="columns"
  >
  </el-data-table>
</template>

<script>
  export default {
    name: "demo",
    data() {
      return {
        url: 'https://easy-mock.com/mock/5b586c9dfce1393a862d034d/example/img',
        // full attributes of columns see: http://element.eleme.io/#/zh-CN/component/table#table-column-attributes
        columns: [
          {prop: 'code', label: '品牌编号'},
          {prop: 'name', label: '品牌名称'},
          {prop: 'alias', label: '品牌别名'},
          {
            prop: 'logoUrl',
            label: '品牌Logo',
            width: '150px'
          },
          {
            prop: 'status',
            label: '状态',
            formatter: row => (row.status === 'normal' ? '启用' : '禁用')
          }
        ]
      }
    }
  }
</script>

<style scoped>

</style>
